<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div id="app">
        <html-a></html-a>
        <html-b></html-b>
    </div>





    <script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
    <script src="https://unpkg.com/axios/dist/axios.min.js"></script>
    <script>

        Vue.component('html-a',{
            data() {
                return {
                    message:"1父组件",
                }
            },
            template:
            `
                <div>
                    <div>{{message}}</div>
                    <p>
                        <html-a-child></html-a-child>
                    </p>
                </div>
            `,
            components:{
                'html-a-child':{
                    data() {
                        return {
                            message:"1子组件",
                        }
                    },
                    template:
                    `
                        <div>{{message}}</div>
                    `,
                }
            }
        })

        Vue.component('html-b',{
            data() {
                return {
                    message:"2父组件",
                }
            },
            template:
            `
                <div>{{message}}</div>
            `
        })



        var app = new Vue({
            el:"#app",
            data:{
                
            },
            methods: {
                
            },
        })
    </script>

</body>
</html>